package com.neborosoft.lib.collections;

import java.util.Iterator;

/**
 * Project: FlyingDog
 * User: stikhonenko
 * Date: 2/6/13
 * Time: 7:40 PM
 */
public class SimpleIterable<T> implements Iterable<T>{
    private Iterator<T> iterator;

    public SimpleIterable(Iterator<T> iterator) {
        this.iterator = iterator;
    }

    public void setIterator(Iterator<T> iterator) {
        this.iterator = iterator;
    }

    @Override
    public Iterator<T> iterator() {
        return iterator;
    }
}
